/*
 * CanvasStringItem.java
 *
 * Created on 4 de Junho de 2007, 20:46
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package com.view.components;

import javax.microedition.lcdui.Canvas;
import javax.microedition.lcdui.Font;
import javax.microedition.lcdui.Graphics;

/**
 *
 * @author $Leandro$
 */
public class CanvasLabel extends CanvasAbstract {
    
    public String text;
    
    public Font font;
    
    public int align;
    
    public CanvasColor color;
    
    /** Creates a new instance of CanvasStringItem */
    public CanvasLabel(Graphics g, int x, int y, int align,String text,Font font, CanvasColor color) {
        super(g);
        
        this.x = x;
        
        this.y = y;
        
        this.align = align;
        
        this.text = text;
        
        this.font = font;
        
        this.color = color;
    }
    
    public void paint() {
        g.setColor(color.rgb);
        g.drawString(text,x,y,align);
    }
    
}
